import os.path

from gxl_ai_utils.utils import utils_file

input_dir = "/home/node54_tmpdata/xlgeng/chat_data/shards_test/tmp"
txt_file_list = utils_file.do_get_list_for_wav_dir(input_dir,suffix='mp3')
res_dict = {}
output_text_scp_path = os.path.join("/home/node54_tmpdata/xlgeng/chat_data/shards_test", "wav.scp")
for path_i in txt_file_list:
    key = utils_file.get_file_pure_name_from_path(path_i)
    value = path_i
    res_dict[key] = value
utils_file.write_dict_to_scp(res_dict,output_text_scp_path)